/**
 * 
 */
package miningMindTest;

import java.util.Iterator;
import java.util.Map;
import java.util.Set;

import miningMinds.*;
/**
 * @author kjysmu
 *
 */
public class SNSLoaderTest {
	
	public static void main(String args[]){
		
		int debug_max = 5;
		int debug_ct = 0;
		
		System.out.println("Start");
		SNSLoader sloader = new SNSLoader("Facebook");
		System.out.println("SNSLoader Init Complete");
		
		Map<String, SNSUserBean> userMap = sloader.getUserMap();
		for (Map.Entry<String, SNSUserBean> userMapEntry : userMap.entrySet()){
			String userID = userMapEntry.getKey();
			SNSUserBean userBean = userMapEntry.getValue();
			System.out.println("userid:" + userID);
			
			Map<String, SNSUserMsgBean> msgMap = userBean.getMsgMap();
			
			for (Map.Entry<String, SNSUserMsgBean> msgMapEntry : msgMap.entrySet()){
				String msgID = msgMapEntry.getKey();
				SNSUserMsgBean userMsgBean = msgMapEntry.getValue();
				String msg = userMsgBean.getMsg();
			
				System.out.println("msgid:" + msgID);
				System.out.println("msg:" + msg);
				
				
				debug_ct++;
				if(debug_ct >= debug_max) System.exit(0);
				
			}
		}
	}
}
